package net.sk.china.city.domain;

import java.util.Date;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import net.sk.china.city.domain.dto.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

/**
 * 订单管理对象 ar_order
 * 
 * @author ruoyi
 * @date 2024-06-06
 */
@Data
public class ArOrder
{
    private static final long serialVersionUID = 1L;

    /** 主键 */
    private Long pkId;

    /** 人员id */
    private Long userId;

    /** 订单编号 */
    private Long orderNumber;

    /** 创建时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date createDatetime;

    /** 支付时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date paymentDatetime;

    /** 订单状态（0待付款，1待发货，2待收货，3已收货，4售后，5退款） */
    private String orderStatus;

    /** 收货人 */
    private String receiver;

    /** 详细地址 */
    private String address;

    /** 联系电话 */
    private String phone;

    /** 支付金额(单位分) */
    private Integer totalPrice;

    /** 0 线上 1 线下 */
    private Integer payMethod;
    /** 订单项信息 */
    private List<ArOrderItem> arOrderItemList;

    /** 数据分权id */
    private Integer deptId;





    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("pkId", getPkId())
            .append("userId", getUserId())
            .append("orderNumber", getOrderNumber())
            .append("createDatetime", getCreateDatetime())
            .append("paymentDatetime", getPaymentDatetime())
            .append("orderStatus", getOrderStatus())
            .append("receiver", getReceiver())
            .append("address", getAddress())
            .append("phone", getPhone())
            .append("totalPrice", getTotalPrice())
            .append("payMethod", getPayMethod())
                .append("deptId", getDeptId())
            .append("arOrderItemList", getArOrderItemList())
            .toString();
    }
}
